package com.hqd.ch03.v39.web.http.server;

import com.hqd.ch03.v39.web.http.HttpInputMessage;
import com.hqd.ch03.v39.web.http.HttpRequest;

import java.net.InetSocketAddress;
import java.security.Principal;

/**
 * 服务端HTTP请求
 */
public interface ServerHttpRequest extends HttpRequest, HttpInputMessage {
    /**
     * 获取认证信息
     *
     * @return
     */
    Principal getPrincipal();

    /**
     * 获取本地地址
     *
     * @return
     */
    InetSocketAddress getLocalAddress();

    /**
     * 获取远程地址
     *
     * @return
     */
    InetSocketAddress getRemoteAddress();
}
